using System.Collections.Generic;
using Abs.Core.Models;
using Abs.Core.DAL.EntityFramework;
using Abs.Core.Models.Room;

namespace Abs.Core.DAL.SetUpDatabase
{
    internal partial class AbsInitializer
    {
        private IList<Room> InitializeRooms(AbsContext absContext)
        {
            var rooms = new List<Room>
                        {
                            new Room{Name = "Air Room"},
                            new Room{Name = "Water Room"},
                            new Room{Name = "Fire Room"},
                            new Room{Name = "Earth Room"}
                        };
            rooms.ForEach(room => absContext.Rooms.Add(room));
            absContext.SaveChanges();

            return rooms;
        }//end of private IList<Room> InitializeRooms(AbsContext absContext)
    }//end of public partial class AbsInitializer
}//end of namespace ABS.DAL